> ## Documentation Index
> Fetch the complete documentation index at: https://sequence-0fb8d9e6-relayer_docs.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Sign-In with Google & Apple

> Learn how to use Social Sign In and get an Id Token using the Browser Plugin and Sequence's Unreal SDK.

<Steps>
  <Step title="Get a Google or Apple Id Token">
    Start by calling the `Get Google Token Id` function. When you make iOS & Android, it will leverage native plugins
    to manage the id token and calls the `IdTokenReceived` event once the process is finished. When you develop and build
    for Mac & Windows, you are required to handle the Sign In Url with the Browser Plugin.

    <Frame>
      <img src="https://mintcdn.com/sequence-0fb8d9e6-relayer_docs/6udOBi1aBhs72bAQ/images/unreal/guides/social_signin/get_token.png?fit=max&auto=format&n=6udOBi1aBhs72bAQ&q=85&s=600e47e8a5a4ca67dd3ffa4ff209697c" width="1628" height="826" data-path="images/unreal/guides/social_signin/get_token.png" />
    </Frame>
  </Step>

  <Step title="Load the URL using the Browser plugin">
    Create a Browser object and load the `Sign In Url`.

    <Frame>
      <img src="https://mintcdn.com/sequence-0fb8d9e6-relayer_docs/6udOBi1aBhs72bAQ/images/unreal/guides/social_signin/load_url.png?fit=max&auto=format&n=6udOBi1aBhs72bAQ&q=85&s=f198212a933c7c1e78c79d2daf08a706" width="1998" height="956" data-path="images/unreal/guides/social_signin/load_url.png" />
    </Frame>
  </Step>

  <Step title="Listen to URL changes">
    In order to get the Id token from Apple & Google, we need to listen to changes in the Url string.
    The id token is inside the Url during the Sign-In process and we need additional functions to parse it out of the Url.

    <Frame>
      <img src="https://mintcdn.com/sequence-0fb8d9e6-relayer_docs/6udOBi1aBhs72bAQ/images/unreal/guides/social_signin/listen_to_url_changes.png?fit=max&auto=format&n=6udOBi1aBhs72bAQ&q=85&s=27e9d9c2b57f7242887be286416689b9" width="1972" height="920" data-path="images/unreal/guides/social_signin/listen_to_url_changes.png" />
    </Frame>
  </Step>

  <Step title="Parse the id token from the URL">
    Let's integrate a few helper functions to parse the id token from the Url.

    **Url to Map:** Convert the Url's query parameters to a string to string map.

    <Frame>
      <img src="https://mintcdn.com/sequence-0fb8d9e6-relayer_docs/6udOBi1aBhs72bAQ/images/unreal/guides/social_signin/url_to_map.png?fit=max&auto=format&n=6udOBi1aBhs72bAQ&q=85&s=04edb04e8d57f64ee27e92dd20f3535c" width="3148" height="878" data-path="images/unreal/guides/social_signin/url_to_map.png" />
    </Frame>

    **Token from Url:** Use the map to check if the `id_token` value exists and return it.

    <Frame>
      <img src="https://mintcdn.com/sequence-0fb8d9e6-relayer_docs/6udOBi1aBhs72bAQ/images/unreal/guides/social_signin/token_from_url.png?fit=max&auto=format&n=6udOBi1aBhs72bAQ&q=85&s=cc97dc4399011045e2376970ec323d1d" width="3152" height="1098" data-path="images/unreal/guides/social_signin/token_from_url.png" />
    </Frame>
  </Step>

  <Step title="Create the session">
    Finally, we check if we got the id token and use the value to create a session using the `Start Oidc Session`.

    <Frame>
      <img src="https://mintcdn.com/sequence-0fb8d9e6-relayer_docs/6udOBi1aBhs72bAQ/images/unreal/guides/social_signin/start_session.png?fit=max&auto=format&n=6udOBi1aBhs72bAQ&q=85&s=c9b397e2ffa5ac7b793ccbf73b5dee40" width="2842" height="1096" data-path="images/unreal/guides/social_signin/start_session.png" />
    </Frame>
  </Step>
</Steps>
